feat: remove visibility flag and warn on deprecated flow endpoint#918
Conversation
The legacy PUT /api/v2/flows/{org} endpoint is deprecated. The
`--visibility` flag was only meaningful for that endpoint, so remove it
from `create flow`. Emit a deprecation warning when neither
`--template-file` nor `--use-empty-template` is provided, since that path
still uses the deprecated endpoint.
|
Claude finished @mbevc1's task in 1m 37s —— View job PR Review: Remove visibility flag and warn on deprecated flow endpoint
Static AnalysisAll checks pass: Review SummaryClean, well-scoped PR. The Findings:
Overall: Looks good to merge. The change is minimal, correct, and well-tested. No bugs, security issues, or performance concerns. |
Removing --visibility in #918 made passing the flag illegal (unknown flag), breaking existing scripts. Restore it as a deprecated flag so it is accepted with a deprecation notice rather than erroring. Drop the hardcoded visibility "private" added in #922 as a backwards- compat shim for servers that still required the field; prod no longer requires it. The field is now sent only when the user explicitly passes the deprecated flag (json omitempty), preserving compatibility with older instances that still mandate it. Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The legacy PUT /api/v2/flows/{org} endpoint is deprecated. The
--visibilityflag was only meaningful for that endpoint, so remove it fromcreate flow. Emit a deprecation warning when neither--template-filenor--use-empty-templateis provided, since that path still uses the deprecated endpoint.Fixes: https://github.com/kosli-dev/server/issues/5790